﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace PluginFramework.Common
{
    /// <summary>
    /// Describes an extension
    /// </summary>
    public class ExtensionInfo:IBrowsable
    {
        private readonly Type _extensionClass;        
        private readonly Type _pointExtended; 
        private readonly string _name;        
        private readonly string _description;
        private readonly bool _enabled;

        public bool Enabled
        {
            get { return _enabled; }
        } 


        public ExtensionInfo(Type extensionClass, Type pointExtension,string name, string description, bool enable)
        {
            _extensionClass = extensionClass;
            _pointExtended = pointExtension;
            _name = name;
            _description = description;
            _enabled = enable;
        }

        public Type ExtensionClass
        {
            get { return _extensionClass; }
        }

        public Type PointExtended
        {
            get { return _pointExtended; }
        }


        public string FormalName
        {
            get { return _extensionClass.FullName; }
        }

        public string Name
        {
            get { return _name; }
        }

        public string Description
        {
            get { return _description; }
        }
    }
}
